home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 49
/
Aminet 49 (2002)(GTI - Schatztruhe)[!][Jun 2002].iso
/
Aminet
/
dev
/
gui
/
Feelin.lha
/
Feelin
/
ObjectList.e
< prev
next >
Wrap
Text File
|
2002-04-02
|
1KB
|
51 lines
OPT PREPROCESS
MODULE 'exec/nodes','exec/semaphores',
'feelin','libraries/feelin'
PROC main()
DEF ss:PTR TO serverSemaphore,
nextc,obj:PTR TO feelinObject,family:PTR TO feelinObject,
nextw
IF ss := FindSemaphore('Feelin\aServer')
IF feelinbase := OpenLibrary('feelin.library',NIL)
ObtainSemaphore(ss)
nextc := ss.server.clients.head
WHILE obj := F_NextObject({nextc})
WriteF('
Client
0x\h\n',obj)
family := F_Get(obj,FA_Family)
nextw := F_Get(family,FA_Family_Head)
WHILE obj := F_NextObject({nextw})
WriteF('|
Window
0x\h (0x\h)\n',obj,obj.parent)
familytree(F_Get(obj,FA_Child),1) ; EXIT CtrlC()
ENDWHILE
ENDWHILE
ReleaseSemaphore(ss)
CloseLibrary(feelinbase)
ENDIF
ENDIF
ENDPROC
PROC familytree(obj:PTR TO feelinObject,level)
DEF i,family,next,child
FOR i := NIL TO level DO WriteF('| ')
WriteF('
Obj
0x\h (0x\h)\n',obj,obj.parent)
IF family := F_Get(obj,FA_Family)
next := F_Get(family,FA_Family_Head)
WHILE child := F_NextObject({next})
familytree(child,level + 1) ; EXIT CtrlC()
ENDWHILE
ENDIF
ENDPROC